/******************************************************************************
 * @File name   :      IMemberPackageRedemptionDao.java
 *
 * @Author      :      JIZHANGS
 *
 * @Date        :      Jul 31, 2015
 *
 * @Copyright Notice: 
 * Copyright (c) 2015 Capgemini, Inc. All  Rights Reserved.
 * This software is published under the terms of the Capgemini Software
 * License version 1.0, a copy of which has been included with this
 * distribution in the LICENSE.txt file.
 * 
 * 
 * ----------------------------------------------------------------------------
 * Date                   Who         Version        Comments
 * Jul 31, 2015 11:16:42 AM        JIZHANGS     1.0            Initial Version
 *****************************************************************************/
package com.cap.bts.crmdp.dealer.redemption.dao;

import java.util.List;

import com.cap.bts.crmdp.dealer.redemption.domain.MemberPackageRedemption;
import com.cap.bts.crmdp.dealer.redemption.dto.RedemptionSubmitDto;
import com.cap.bts.framework.common.dao.IBaseDao;
import com.cap.bts.framework.common.exception.AppException;

/**
 *
 */
public interface IPackageRedemptionDao extends IBaseDao<MemberPackageRedemption, Long> {
    
    List<Object[]> getPackageListDetailByPackageId(Long packageId,Integer status) throws AppException;

    MemberPackageRedemption checkActivicationCode(RedemptionSubmitDto dto) throws AppException;
    
    void updateMemberPackageRedemption(MemberPackageRedemption mp) throws AppException;
    
    MemberPackageRedemption useActivicationCode(RedemptionSubmitDto dto) throws AppException;
    
    List<Object[]> getPackageListReportDetailByPackageId(Long packageId) throws AppException;
    
    List<Object[]> getPackageRedemListByPackageId(Long packageId) throws AppException;
    
    List<String> getPackageMemberBenfitByPackageId(Long packageId) throws AppException;

	List<Object[]> getPackageListReportDetailByPackageIds(List<Long> packageIds) throws AppException;
	
	public void deleteByPackageId(Long packageId) throws AppException;
	
	public Long getUsedRedemptionCountByPackageNumber(String packageNumber) throws AppException;
}
